#ifndef QBCISERIAL_H
#define QBCISERIAL_H

#include <QObject>
#include <QSerialPort>
#include <QThread>
#include <QtDebug>
#include <QLogger>

class QBciSerial : public QObject
{
Q_OBJECT

public:
    QBciSerial();
    ~QBciSerial();

public:
    void setPortname(const QString &portname);
    void write(const QByteArray &mesg);
    void SerialInit();

public slots:
    void beforeStart();
    void beforeStop();

public:
    QThread *serialThread;

private:
    QSerialPort *serial;

private:
    QString PortName;
};

#endif // QBCISERIAL_H
